package com.jf.tzkk.chain.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.jf.tzkk.chain.entity.LcUserRechargeRecord;
import org.apache.ibatis.annotations.Update;

public interface UserRechargeRecordMapper extends BaseMapper<LcUserRechargeRecord> {

    /**
     * 处理过期订单
     */
    @Update("UPDATE lc_user_recharge_record SET status = 3 WHERE status = 0 AND TIMESTAMPDIFF(MINUTE, time, NOW()) > 30")
    void timeOut();
}
